﻿// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
//
// 本项目主要遵循 MIT 许可证和 Apache 许可证（版本 2.0）进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
//
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动！任何基于本项目二次开发而产生的一切法律纠纷和责任，我们不承担任何责任！

using Admin.NET.Core;
using Magicodes.ExporterAndImporter.Core;
using Magicodes.ExporterAndImporter.Excel;
using System.ComponentModel.DataAnnotations;

namespace Admin.NET.Application;

/// <summary>
/// 车间管理基础输入参数
/// </summary>
public class processmanageBaseInput
public class CarWorkShoopBaseInput
{
    /// <summary>
    /// 主键Id
    /// </summary>
    public virtual long? Id { get; set; }
    
    /// <summary>
    /// 编码
    /// </summary>
    public virtual string? encoding { get; set; }
    public virtual string? WorkShopCoding { get; set; }
    
    /// <summary>
    /// 名称
    /// </summary>
    public virtual string? name { get; set; }
    public virtual string? WorkShopName { get; set; }
    
    /// <summary>
    /// 描述
    /// </summary>
    public virtual string? description { get; set; }
    public virtual string? WorkShopDescribe { get; set; }
    
}

/// <summary>
/// 车间管理分页查询输入参数
/// </summary>
public class PageprocessmanageInput : BasePageInput
public class PageCarWorkShoopInput : BasePageInput
{
    /// <summary>
    /// 编码
    /// </summary>
    public string? encoding { get; set; }
    public string? WorkShopCoding { get; set; }
    
    /// <summary>
    /// 名称
    /// </summary>
    public string? name { get; set; }
    public string? WorkShopName { get; set; }
    
    /// <summary>
    /// 描述
    /// </summary>
    public string? description { get; set; }
    public string? WorkShopDescribe { get; set; }
    
    /// <summary>
    /// 选中主键列表
    /// </summary>
     public List<long> SelectKeyList { get; set; }
}

/// <summary>
/// 车间管理增加输入参数
/// </summary>
public class AddprocessmanageInput
public class AddCarWorkShoopInput
{
    /// <summary>
    /// 编码
    /// </summary>
    [MaxLength(32, ErrorMessage = "编码字符长度不能超过32")]
    public string? encoding { get; set; }
    public string? WorkShopCoding { get; set; }
    
    /// <summary>
    /// 名称
    /// </summary>
    [MaxLength(32, ErrorMessage = "名称字符长度不能超过32")]
    public string? name { get; set; }
    [MaxLength(32, ErrorMessage = "名称字符长度不能超过32")]
    public string? WorkShopName { get; set; }
    
    /// <summary>
    /// 描述
    /// </summary>
    [MaxLength(32, ErrorMessage = "描述字符长度不能超过32")]
    public string? description { get; set; }
    public string? WorkShopDescribe { get; set; }
    
}

/// <summary>
/// 车间管理删除输入参数
/// </summary>
public class DeleteprocessmanageInput
public class DeleteCarWorkShoopInput
{
    /// <summary>
    /// 主键Id
    /// </summary>
    [Required(ErrorMessage = "主键Id不能为空")]
    public long? Id { get; set; }
    
}

/// <summary>
/// 车间管理更新输入参数
/// </summary>
public class UpdateprocessmanageInput
public class UpdateCarWorkShoopInput
{
    /// <summary>
    /// 主键Id
    /// </summary>    
    [Required(ErrorMessage = "主键Id不能为空")]
    public long? Id { get; set; }
    
    /// <summary>
    /// 编码
    /// </summary>    
    [MaxLength(32, ErrorMessage = "编码字符长度不能超过32")]
    public string? encoding { get; set; }
    
    /// <summary>
    /// 名称
    /// </summary>    
    [MaxLength(32, ErrorMessage = "名称字符长度不能超过32")]
    public string? name { get; set; }
    public string? WorkShopCoding { get; set; }
    
    /// <summary>
    /// 名称
    /// </summary>    
    [Dict("operation_type_management", AllowNullValue=true)]
    [MaxLength(32, ErrorMessage = "类型字符长度不能超过32")]
    public string? type { get; set; }
    
    /// <summary>
    /// 报工模式
    /// </summary>    
    [Dict("reporting_mode", AllowNullValue=true)]
    [MaxLength(32, ErrorMessage = "报工模式字符长度不能超过32")]
    public string? reportingmode { get; set; }
    [MaxLength(32, ErrorMessage = "名称字符长度不能超过32")]
    public string? WorkShopName { get; set; }
    
    /// <summary>
    /// 描述
    /// </summary>    
    [MaxLength(32, ErrorMessage = "描述字符长度不能超过32")]
    public string? description { get; set; }
    public string? WorkShopDescribe { get; set; }
    
}

/// <summary>
/// 车间管理主键查询输入参数
/// </summary>
public class QueryByIdprocessmanageInput : DeleteprocessmanageInput
public class QueryByIdCarWorkShoopInput : DeleteCarWorkShoopInput
{
}

/// <summary>
/// 车间管理数据导入实体
/// </summary>
[ExcelImporter(SheetIndex = 1, IsOnlyErrorRows = true)]
public class ImportprocessmanageInput : BaseImportInput
public class ImportCarWorkShoopInput : BaseImportInput
{
    /// <summary>
    /// 编码
    /// </summary>
    [ImporterHeader(Name = "编码")]
    [ExporterHeader("编码", Format = "", Width = 25, IsBold = true)]
    public string? encoding { get; set; }
    
    /// <summary>
    /// 名称
    /// </summary>
    [ImporterHeader(Name = "名称")]
    [ExporterHeader("名称", Format = "", Width = 25, IsBold = true)]
    public string? name { get; set; }
    
    /// <summary>
    /// 类型 关联值
    /// </summary>
    [ImporterHeader(IsIgnore = true)]
    [ExporterHeader(IsIgnore = true)]
    public string? type { get; set; }
    public string? WorkShopCoding { get; set; }
    
    /// <summary>
    /// 类型 文本
    /// 名称
    /// </summary>
    [Dict("operation_type_management")]
    [ImporterHeader(Name = "类型")]
    [ExporterHeader("类型", Format = "", Width = 25, IsBold = true)]
    public string typeDictLabel { get; set; }
    
    /// <summary>
    /// 报工模式 关联值
    /// </summary>
    [ImporterHeader(IsIgnore = true)]
    [ExporterHeader(IsIgnore = true)]
    public string? reportingmode { get; set; }
    
    /// <summary>
    /// 报工模式 文本
    /// </summary>
    [Dict("reporting_mode")]
    [ImporterHeader(Name = "报工模式")]
    [ExporterHeader("报工模式", Format = "", Width = 25, IsBold = true)]
    public string reportingmodeDictLabel { get; set; }
    [ImporterHeader(Name = "名称")]
    [ExporterHeader("名称", Format = "", Width = 25, IsBold = true)]
    public string? WorkShopName { get; set; }
    
    /// <summary>
    /// 描述
    /// </summary>
    [ImporterHeader(Name = "描述")]
    [ExporterHeader("描述", Format = "", Width = 25, IsBold = true)]
    public string? description { get; set; }
    public string? WorkShopDescribe { get; set; }
    
}
